<script type="text/javascript" charset="utf-8">
	$(document).ready(function() {
		$('#example').dataTable( {
			"sScrollY": "800px",
			"bPaginate": false,
			"bScrollCollapse": true
		} );
	});
</script>

<script type="text/javascript">
	$(document).ready(function() {
	});

	function laporan(pageURL, title,w,h){

		var periode_awal=document.getElementById('tanggal_awal').value;

		var periode_akhir=document.getElementById('tanggal_akhir').value;

		if ((periode_awal=='')||(periode_akhir=='')){

			alert('Isilah periode awal dan akhir');

		}else{

			var left = (screen.width/2)-(w/2);

			var top = (screen.height/2)-(h/2);

			var targetWin = window.open ('<?=site_url();?>/mcm/view_lap_biaya_periode/'+periode_awal+'/'+periode_akhir, title, 'toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=yes, resizable=no, copyhistory=no, width='+w+', height='+h+', top='+top+', left='+left);

			

			document.getElementById('tanggal_awal').value='';

			document.getElementById('tanggal_akhir').value='';

		}
	}

	

	$(function(){

		$("#tanggal_awal").datepicker({dateFormat: 'yy-mm-dd' });

	})	

	

	$(function(){

		$("#tanggal_akhir").datepicker({dateFormat: 'yy-mm-dd' });

	})	

	

		

	function klick_tanggal_awal(){

		var tanggal = document.getElementById("tanggal_awal");

		tanggal.focus();

	}

	

	function klick_tanggal_akhir(){

		var tanggal = document.getElementById("tanggal_akhir");

		tanggal.focus();

	}

	

	function batal2(){

		//document.location.href="<?=site_url();?>/mcm";
		
		$.fancybox.close();
	}

	

</script>


	<?php 
		if(validation_errors())
		{
	?>
			<ul class="message error grid_12">
				<li><?=validation_errors()?>asdasd</li>
				<li class="close-bt"></li>
			</ul>	
	<?php
		} 
	?>
<div id="page-heading"><h1>Mandiri Cash Management Verifikasi Data</h1></div>
<table border="0" width="100%" cellpadding="0" cellspacing="0" id="content-table">
<tr>
	<th rowspan="3" class="sized"><img src="<?php echo base_url() ?>asset/admin/images/shared/side_shadowleft.jpg" width="20" height="300" alt="" /></th>
	<th class="topleft"></th>
	<td id="tbl-border-top">&nbsp;</td>
	<th class="topright"></th>
	<th rowspan="3" class="sized"><img src="<?php echo base_url() ?>asset/admin/images/shared/side_shadowright.jpg" width="20" height="300" alt="" /></th>
</tr>
<tr>
	<td id="tbl-border-left"></td>
	<td> 
		<div id="content-table-inner">
		<div id="table-content">
		<table border="0" width="100%" cellpadding="0" cellspacing="0">
		
		<tr valign="top">
			<td>			
			
					<div id="step-holder">
						<div class="step-no">1</div>
						<div class="step-light-left">
							<?php 
								echo anchor('mcm/index', 'List Data Upload MCM');
							?>
						</div>
						<div class="step-light-right">&nbsp;</div>
						<div class="step-no">2</div>
						<div class="step-light-left">
							<?php  
								echo anchor('mcm/insert', 'Tambah Data');
							?>
						</div>
						<div class="step-light-right">&nbsp;</div>
						<div class="step-no">3</div>
						<div class="step-dark-left">
							<?php  
								echo anchor('mcm/verifikasi', 'Verifikasi Data');
							?>
						</div>
			 
						<div class="step-dark-round">&nbsp;</div>
											
						<div class="clear"></div>
					</div>
			
				 
			<?php 
				$attributes = array('name' => 'form1', 'id' => 'form1', 'class'=>'block-content form');
				echo form_open_multipart('mcm/process_update', $attributes);
			?>
			 
			<br/><br/>
				<table border="0" width="100%" cellpadding="0" cellspacing="0" class="display" id="example">
				<thead>
					<tr>										
						<th class="table-header-repeat line-left minwidth-0" style="text-align: center">No.</th> 
						<th class="table-header-repeat line-left minwidth-1"><a href="">Tanggal</a></th>				 				
						<th class="table-header-repeat line-left minwidth-0"><a href="">Rincian Transaksi</a></th>	
						<!--<th class="table-header-repeat line-left minwidth-1"><a href="">Uraian</a></th>  -->
						<th class="table-header-repeat line-left minwidth-1" style="text-align: center"><a href="">Debet</a></th>	
						<th class="table-header-repeat line-left minwidth-1" style="text-align: center"><a href="">Kredit</a></th>							
						<th class="table-header-repeat line-left minwidth-1" style="text-align: center"><a href="">Aksi</a></th>	  				
					</tr>
				</thead>
				<tbody>
				 <? //echo "<input type='hidden' name='count_result'  id='count_result' value='".$count_result ."'>"?> 
				<?php 
				$j=0;
				foreach($results->result() as $row) 
				{
				$j++;
				?>
					<tr class="alternate-row">
						<td align="left" valign="top">
							<?=$j + $param3?> <?//echo  "";?>
							<?//=$row->id?> 
							<? echo "<input type='hidden' name='id'  id='id' value='".$row->id ."'>"?>  
							<? echo "<input type='hidden' name='id_mcm'  id='id_mcm' value='".$row->id_mcm ."'>"?>
						</td>
						<td align="left" valign="top">
							 <?php 
								$tgl1=$tanggal 	= date('d-M-Y H:i:s', strtotime($row->tanggal));  
							?> 
							<?=$tgl1?> 
							<? echo "<input type='hidden' name='tanggal'  id='tanggal' value='".$row->tanggal ."'>"?>
						</td>
						<td align="left" valign="top">
							<?=$row->rincian_transaksi?>  
							<? echo "<input type='hidden'   name='rincian_transaksi'  id='rincian_transaksi' value='".$row->rincian_transaksi."'>"?>
						</td> 
					 
						<td align="right" valign="top">
							<?=convert_rupiah_non_rp($row->debet)?> 
							<? echo "<input type='hidden' style='text-align:right' name='debet'  id='debet' value='".$row->debet ."' readonly='readonly' >";?>  
						</td> 
						<td align="right" valign="top">
							<?=convert_rupiah_non_rp($row->kredit)?> 
							<? echo "<input type='hidden' style='text-align:right' name='kredit'  id='kredit' value='".$row->kredit ."' readonly='readonly' >";?>  
						</td> 
									 
					  
						 
						 
						<td align="center" valign="top">
							 
							 
										<script>
									 
										var counter = 0;
										
										$(document).ready(function(){
										counter=counter+1;
										
										$("#getakun"+counter).fancybox({ 
											'autoDimensions': true,
											'autoScale'     : true,
											'transitionIn'  : 'elastic',
											'transitionOut' : 'elastic',
										});
										}); 
										</script>
										<a id="getakun<?=$j;?>" href="<?=base_url().'index.php/mcm/verifikasi_detail/'.$row->id?>">[Verifikasi]</a>
											
									 
						</td> 
						 
					</tr>
				<?php  } ?>	
				</tbody> 
				</table> 
			 
				</form>		
		</div>
		</td>
		</tr> 		 
	</div> 
	</td>
</tr>
</table>
 
		<!--  start paging..................................................... -->
			<table border="0" cellpadding="0" cellspacing="0" id="paging-table">
			<tr>
			<td>
			 
				<?php echo $this->pagination->create_links(); ?>
			</td>
			<td>  
			</td>
			</tr>
			</table>
			<!--  end paging................ -->
		
<div class="clear"></div>
 
</div>
</div>	
</td>
<td id="tbl-border-right"></td>
</tr>
<tr>
	<th class="sized bottomleft"></th>
	<td id="tbl-border-bottom">&nbsp;</td>
	<th class="sized bottomright"></th>
</tr>
</table>
 


			